import java.util.Scanner;


public class OddAss {

	public static void main(String[] args)
	{
		Scanner s = new Scanner(System.in);
		System.out.println("Enter the size of the list to be sorted:Default is 5");
		
		int size =5;
		
		try
		{
			size = s.nextInt();
		}
		catch(Exception e)
		{
			size =5;
			s= new Scanner(System.in);
			System.out.println("Default size is set as 5:"+e+"\n");
		}
		
		System.out.println("Enter the number to be sorted:");
					
		int array[] = new int[size];
		int i=0;
		
		while(i<size)
		{
			try
			{
				array[i] = s.nextInt();
				i++;					
			}
			catch(Exception e)
			{
				System.out.println("Invalid value entered:"+e);
				s = new Scanner(System.in);
			}
		}

		// printing the odd number
		for (i=0;i<size;i++)
		{
			if((array[i]%2) != 0)
				System.out.println("\n"+array[i]);
		}
		s.close();
	}

}
